﻿using System;


namespace Class_Object
{
    class Program
    {
        static void Main(string[] args)
        {
            //Student

            Student st = new Student();

            st.SetValues();
            Console.Clear();
            st.ShowInfo();

            Console.ReadKey();
            Console.Clear();

            //Triangle

            Triangle tr = new Triangle();

            tr.SetValues();
            Console.Clear();
            tr.ShowInfo();
            Console.WriteLine("Result = " + tr.TestTriangle());

            Console.ReadKey();
            Console.Clear();

            //Account

            Account acc1 = new Account();

            acc1.Set_values();

            Console.WriteLine("\n");
            
            int opt = 0;
            string message = "No Message";
            Label1:
                Console.Clear();
                Console.WriteLine("Balance = " + acc1.GetBalance());
                Console.WriteLine(message);
                Console.WriteLine("Choose Option (Logged Into Acc No. " + acc1.GetID() + ")\n1. Deposit\n2. Withdraw\n3. LogOut");
                opt = Convert.ToByte(Console.ReadLine());
                if (opt == 1)
                {                   
                    message = acc1.Deposit();
                    goto Label1;
                }
                else if (opt == 2)
                {
                    message = acc1.Withdraw();
                    goto Label1;
                }
                Console.Clear();
                acc1.ShowDetails();
                Console.WriteLine("\nLogged Out");
        }
    }
}
